package com.wrx.club_management_backend.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wrx.club_management_backend.common.AjaxResult;
import com.wrx.club_management_backend.entity.ClubAchievement;
import com.wrx.club_management_backend.mapper.ClubAchievementMapper;
import com.wrx.club_management_backend.service.ClubAchievementService;
import org.springframework.stereotype.Service;

@Service
public class ClubAchievementServiceImpl extends ServiceImpl<ClubAchievementMapper, ClubAchievement> implements ClubAchievementService {
    @Override
    public AjaxResult create(ClubAchievement achievement) {
        this.save(achievement);
        return AjaxResult.success("添加成功");
    }

    @Override
    public AjaxResult num() {
        int size = this.list().size();
        return AjaxResult.success(size);
    }
}
